package com.os.user.service;

import com.os.user.bean.User;

import java.util.List;

/**
 * @author 
 * @version v1.0.0
 * @description User 接口
 * @date Created in 2018-08-26 22:34:03
 */
public interface UserService {

    /**
     * 通过ID查找对象
     * @param userId
     * @return
     */
    User getById(Integer userId) throws Exception ;

    /**
     * 列表
     * @param user
     * @return
     */
    List<User> list(User user) throws Exception ;

    /**
     * 删除
     * @param userId
     * @return
     */
    int deleteById(Integer userId) throws Exception ;

    /**
     * 添加
     * @param user
     * @return
     */
    User save(User user) throws Exception ;

    /**
     * 更新
     * @param user
     * @return
     */
    User update(User user) throws Exception ;
}
